package cn.ycq.im.chat.handle;

import cn.ycq.im.chat.CmdHandler;
import cn.ycq.im.chat.CmdTransport;
import cn.ycq.im.chat.CmdType;
import com.alibaba.fastjson.JSON;
import io.netty.channel.ChannelHandlerContext;
import lombok.extern.slf4j.Slf4j;

/**
 * @author yuchaoqun
 * @email chaoqunyu9311@163.com
 * @date 2021.03.21 10:19
 */
@Slf4j
public class HeartCmdHandler implements CmdHandler {
    @Override
    public CmdType getCmdType() {
        return CmdType.HEART;
    }

    @Override
    public void handle(ChannelHandlerContext ctx, CmdTransport cmdTransport) {
        log.info("接受到客户端心跳："+ JSON.toJSONString(cmdTransport));
    }
}
